package com.c2soft.nepalcmx.services;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.c2soft.nepalcmx.command.AccountDetailCommand;
import com.c2soft.nepalcmx.command.AccountDetailCommand;
import com.c2soft.nepalcmx.command.BrokerFormCommand;
import com.c2soft.nepalcmx.command.TradeBookCommand;
import com.c2soft.nepalcmx.dao.BrokerAccountDetailDAO;

@Service
public class BrokerAccountDetailService {
	
	@Autowired
	private BrokerAccountDetailDAO brokerAccountDetailDAO;





public void updateUserService(AccountDetailCommand account) {
	brokerAccountDetailDAO.updateAccountDetailService(account);
}

public void updateAccountService(AccountDetailCommand account) {
	brokerAccountDetailDAO.updateAccountDetailService(account);
}

public List<AccountDetailCommand> getBrokerDetail(String brokerId) {
	
	return brokerAccountDetailDAO.findBrokerAcctDetails(brokerId);
}

public List<AccountDetailCommand> getBrokersAccount() {
	
	return brokerAccountDetailDAO.findBrokersAccount();
}
public List<AccountDetailCommand> getBrokerAccounts(String brokerId) {
	
	return brokerAccountDetailDAO.findBrokerAccountDetails(brokerId);
}
public List<AccountDetailCommand> getExchangeAccounts() {
	
	return brokerAccountDetailDAO.findExchangeAccountDetails();
}

public void deleteBrokerAccount(String brokerId) {
	
 brokerAccountDetailDAO.deleteBrokerAccount(brokerId);
}

public void deleteUserAccount(String userId) {
	
	 brokerAccountDetailDAO.deleteUserAccount(userId);
	}
}
